﻿$(document).ready(function () {
    alert("Hello");
    var baseUrl = '@Url.Content("~/")';
    $("#jqgEmployee").jqGrid({
        data: 'response',
        root: 'rows',
        url: baseUrl + 'Employee/MyData',
        datatype: 'json',
        mtype: 'POST',
        colNames: ['First Name', 'Last Name', 'Date Of Birth', 'City'],
        colModel: [
    { name: 'FirstName', index: 'FirstName', width: 100 },
    { name: 'LastName', index: 'LastName', width: 100 },
    { name: 'DateOfBirth', index: 'DateOfBirth', width: 80 },
    { name: 'City', index: 'City', width: 80}],
        pager: '#jqgpEmployee',
        rowNum: 5,
        width: '100%',
        height: '100%',
        pagination: true,
        gridView: true,
        sortable: true,
        sortorder: 'asc',
        viewrecords: true,
        caption: 'Employee List',
        imgpath: baseUrl + 'content/themes/base/images'
    });
});